package com.sczmgk.hotline.entity;


import com.hyphenate.chat.EMMessage;

import java.util.Comparator;


public  class EMMMessageComparator implements Comparator<EMMessage> {
    @Override
    public int compare(EMMessage lhs, EMMessage rhs) {
        long time1 = Long.valueOf(lhs.getMsgTime());
        long time2 = Long.valueOf(rhs.getMsgTime());
        return (int) (time1 - time2);
    }
}
